const nodata = require('../tw-lib-base/no-data/props')
const commonProps = require('../tw-lib-base/chart/common-props')
const axisProps = require('../tw-lib-base/chart/axis-props')
const datazoomProps = require('../tw-lib-base/chart/datazoom-props')
const tooltipProps = require('../tw-lib-base/chart/tooltip-props')

module.exports = {
  ...commonProps,

  ...axisProps,
  ...datazoomProps,
  ...tooltipProps,

  data: {
    type: Array,
    default () {
      return [
        ['姓名', '张思睿', '李福娥', '王飞虎'],
        ['语文', 20, 30, 50],
        ['数学', 30, 40, 30],
        ['英语', 25, 25, 50],
        ['物理', 40, 30, 30]
      ]
    },
    name: '图表数据集',
    filedType: 'api'
  },

  gridRight: {
    type: String,
    default: '10%',
    name: 'Grid右侧距离',
    filedType: 'string'
  },

  yLabel: {
    type: String,
    default: '%',
    name: '坐标轴单位',
    filedType: 'string'
  },

  barMaxWidth: {
    type: String,
    default: '50%',
    name: '柱子最大宽度',
    filedType: 'string'
  },

  isStack: {
    type: String,
    default: 'stack',
    name: '坐标轴堆叠',
    filedType: 'string'
  },

  ...nodata
}
